﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace AAA.Recognition
{
    public class Sensor
    {
        private int _iUpCrossCount;
        private int _iDownCrossCount;
        private int _iLeftCrossCount;
        private int _iRightCrossCount;

        public int UpCrossCount
        {
            get { return _iUpCrossCount; }
            set { _iUpCrossCount = value; }
        }

        public int DownCrossCount
        {
            get { return _iDownCrossCount; }
            set { _iDownCrossCount = value; }
        }

        public int LeftCrossCount
        {
            get { return _iLeftCrossCount; }
            set { _iLeftCrossCount = value; }
        }

        public int RightCrossCount
        {
            get { return _iRightCrossCount; }
            set { _iRightCrossCount = value; }
        }

        public bool IsMatch(Sensor sensor)
        {
            return UpCrossCount == sensor.UpCrossCount && 
                   DownCrossCount == sensor.DownCrossCount &&
                   LeftCrossCount == sensor.LeftCrossCount &&
                   RightCrossCount == sensor.RightCrossCount;
        }

    }
}
